package com.itheima.demo;

public class Demo实现方式 {
    public static void main(String[] args) {
        //创建子类对象;
        myRun run = new myRun();
        //创建Thread对象;
        Thread mt = new Thread(run);
        mt.setName("线程一");
        //d调用start方法,开启线程;
        mt.start();
        Thread mt1 = new Thread(run);
        mt1.setName("线程二");
        mt1.start();


    }
}
